<template>
  <view class="no-data">
    <image :src="noDataSrc"></image>
    <view class="no-data-tooltip">{{ noDataTitle }}</view>
  </view>
</template>

<script setup>
defineProps({
  noDataSrc: {
    type: String,
    default: '../../static/device/nodevice.png',
  },
  noDataTitle: {
    type: String,
    default: '暂无数据',
  },
})
</script>

<style scoped>
.no-data {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.no-data image {
  width: 160rpx;
  height: 160rpx;
}
.no-data-tooltip {
  margin-top: 10rpx;
  font-size: 28rpx;
  color: #6f6f6f;
}
</style>
